//
//  BodiView.m
//  UI10_HomeWork
//
//  Created by Bodi on 16/6/17.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "BodiView.h"

@implementation BodiView

- (instancetype)initWithFrame:(CGRect)frame withLabelText:(NSString *)text withPlaceholder:(NSString *)placeholder{
    self = [super initWithFrame:frame];
    if (self) {
        self.label = [[UILabel alloc]init];
        self.label.text = text;
        self.label.frame = CGRectMake(0, 0, CGRectGetWidth(self.bounds) / 3, CGRectGetHeight(self.bounds));
        self.textField = [[UITextField alloc]init];
        self.textField.text = placeholder;
        self.textField.frame = CGRectMake(CGRectGetWidth(self.bounds)/ 3,0 , CGRectGetWidth(self.bounds)/ 3 * 2, CGRectGetHeight(self.bounds));
        [self addSubview:_label];
        [self addSubview:_textField];
//        NSLog(@"%@", self.textField.text);
        
    }
    return self;



}




/*
// Only override drawRect: if you perform custom drawing.
// An empty implementation adversely affects performance during animation.
- (void)drawRect:(CGRect)rect {
    // Drawing code
}
*/

@end
